import java.util.Random;

public class AICPU_Easy {

	public static int AICPU_Easy = 0;
	public static int C2p = 0;
	public static boolean shuffled = false;
	public static int[] myArray = new int[] { 1, 1, 1, 2, 2, 2, 3, 3, 3, 4, 4,
			4, 5, 5, 5, 6, 6, 6, 7, 7, 7, 8, 8, 8, 9, 9, 9 };

	public static void shuffle() {
		Random rgen = new Random();
		for (int i = 0; i < myArray.length; i++) {
			int randomPosition = rgen.nextInt(myArray.length);
			int temp = myArray[i];
			myArray[i] = myArray[randomPosition];
			myArray[randomPosition] = temp;
		}
	}

	public static void main(String[] arguments, int x) {
		if (shuffled == false) {
			shuffle();
			System.out.println("shuffled");
			shuffled = true;
		} else {
			System.out.println("already shuffled");
		}
		Interface2.input = myArray[x];
		if (C2p == 0) {
			Card.playCard6();
			C2p++;
		} else if (C2p == 1) {
			Card.playCard5();
			C2p++;
		} else if (C2p == 2) {
			Card.playCard4();
			C2p++;
		} else if (C2p == 3) {
			Card.playCard3();
			C2p++;
		} else if (C2p == 4) {
			Card.playCard2();
			C2p++;
		} else if (C2p == 5) {
			Card.playCard1();
			C2p = 0;
		}
		AICPU_Easy++;
		Card.hideDealer();
		InterfaceCPU_Easy.main(null);

	}
}
